package com.qsl.rpc;

import com.qsl.rpc.entity.Person;
import com.qsl.rpc.entity.User;
import com.qsl.rpc.service.IPersonService;
import com.qsl.rpc.service.IUserService;

/**
 * @author 青石路
 * @date 2021/1/16 19:49
 */
public class Client {

    public static void main(String[] args) throws Exception {

        /*IUserService userService = (IUserService)Stub.getStub(IUserService.class);
        User user = userService.getUserByName("青石路");
        System.out.println(user);*/

        IPersonService personService = (IPersonService)Stub.getStub(IPersonService.class);
        Person person = personService.getPersonByPhoneNumber("123");
        System.out.println(person);
    }
}
